using System;

namespace TagTool.Devices.Midi
{
    /// <summary> Represents a channel voice message </summary>
    public class PitchWheelMessage : MidiChannelMessage
    {
        public PitchWheelMessage(uint highData, uint lowData)
            : base(highData, lowData)
        {
        }        
         
        /// <summary> Property Controller </summary>
        /// <remarks> Controller is in the 7 bits of the 2nd byte in highData </remarks>
        public uint Controller
        {
            get
            {
                return ((HighData >> 8) & (uint)MidiMessageMask.Data);
            }
        }

        /// <summary> Property Value </summary>
        /// <remarks> Value is in the 7 bits of the 3nd byte in highData </remarks>
        public uint Value
        {
            get
            {
                return ((HighData >> 16) & (uint)MidiMessageMask.Data);
            }
        }
    }
}
